package com.xjh.basestudy.designmode.behaviorMode.behaviorMode3_ChainOfResponsibility.p2_chain;

/**
 * @Author XuJianHua
 * @Date 2022/10/4 14:39
 * @Description

 */
public class CFO extends Approver {

    public CFO(String name) {
        super(name);
    }

    @Override
    public void approve(int amount) {
        if (amount <= 10000) {
            System.out.println("审批通过。【财务总监：" + name + "】");
        } else {
            System.out.println("驳回申请。【财务总监：" + name + "】");
        }
    }

}